package ${package.Service};

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

import com.hbsj.core.entity.MapResponse;
import com.hbsj.core.entity.PageResponse;
import com.hbsj.core.entity.ListResponse;
import java.util.Date;
import java.math.BigDecimal;


@FeignClient(value = "${entity?lower_case}-service")
public interface ${entity}Service {

    @PostMapping(value = "/${entity?lower_case}/create")
    MapResponse create(
<#list table.fieldsWithoutIdAndCU as field>
	    @RequestParam("${field.propertyName}") ${field.propertyType} ${field.propertyName}<#if field_index != table.fieldsWithoutIdAndCU?size-1>,</#if>
</#list>
    );

    @PostMapping(value = "/${entity?lower_case}/update")
    MapResponse update(
<#list table.fieldsWithoutCU as field>
	    @RequestParam("${field.propertyName}") ${field.propertyType} ${field.propertyName}<#if field_index != table.fieldsWithoutCU?size-1>,</#if>
</#list>
    );

    @PostMapping(value = "/${entity?lower_case}/del")
    MapResponse del(@RequestParam("id") long id);


    @GetMapping(value = "/${entity?lower_case}/get")
    MapResponse get(@RequestParam("id") long id);

    @GetMapping("/${entity?lower_case}/getpagelist")
    PageResponse getPageList(
            int current,
            int pagesize
    );
}